home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 22 / AACD 22.iso / AACD / Programming / powerd / lib / startup_dos_ieee.ass < prev    next >
Encoding:
Text File  |  1980-12-11  |  1.2 KB  |  58 lines

  1. _START    move.l    a0,_arg
  2.     movea.l    $4.w,a6
  3.     lea    (DOSName,pc),a1
  4.     moveq    #37,d0
  5.     jsr    (-552,a6)        ; OpenLibrary()
  6.     move.l    d0,_DOSBase
  7.     beq.s    .FINISH
  8.  
  9.     movea.l    d0,a6
  10.     jsr    (-60,a6)        ; Output()
  11.     move.l    d0,_stdout
  12.     jsr    (-54,a6)        ; Input()
  13.     move.l    d0,_stdin
  14.  
  15.     movea.l    $4.w,a6
  16.     lea    (BasName,pc),a1
  17.     moveq    #0,d0
  18.     jsr    (-552,a6)        ; OpenLibrary()
  19.     move.l    d0,_MathIEEEDoubBasBase
  20.     beq.s    .CLOSEDOS
  21.  
  22.     lea    (TraName,pc),a1
  23.     moveq    #0,d0
  24.     jsr    (-552,a6)        ; OpenLibrary()
  25.     move.l    d0,_MathIEEEDoubTransBase
  26.     beq.s    .CLOSEBAS
  27.  
  28.     xref    _main
  29.     jsr    _main        ; a6 is stored
  30.     move.l    d0,d2
  31.  
  32.     movea.l    _MathIEEEDoubTransBase,a1
  33.     jsr    (-414,a6)        ; CloseLibrary()
  34. .CLOSEBAS    movea.l    _MathIEEEDoubBasBase,a1
  35.     jsr    (-414,a6)        ; CloseLibrary()
  36. .CLOSEDOS    movea.l    _DOSBase,a1
  37.     jsr    (-414,a6)        ; CloseLibrary()
  38. .FINISH    move.l    d2,d0
  39.     rts
  40. ****************************************
  41.     xdef    _DOSBase
  42.     xdef    _MathIEEEDoubBasBase
  43.     xdef    _MathIEEEDoubTransBase
  44.     xdef    _arg
  45.     xdef    _stdout
  46.     xdef    _stdin
  47. ****************************************
  48. _DOSBase            dc.l    0
  49. _MathIEEEDoubBasBase    dc.l    0
  50. _MathIEEEDoubTransBase    dc.l    0
  51. _arg            dc.l    0
  52. _stdout            dc.l    0
  53. _stdin            dc.l    0
  54. ****************************************
  55. DOSName    dc.b    'dos.library',0
  56. BasName    dc.b    'mathieeedoubbas.library',0
  57. TraName    dc.b    'mathieeedoubtrans.library',0
  58.